Skip to content

feat: Add tutorial about the ORM system - #15468

Open
CarlSchwan wants to merge 2 commits into
masterfrom
carl/orm
Open

feat: Add tutorial about the ORM system#15468
CarlSchwan wants to merge 2 commits into
masterfrom
carl/orm

Conversation

@CarlSchwan

@CarlSchwan CarlSchwan commented Aug 20, 2026

Copy link
Copy Markdown
Member

Remove old stuff about QBMapper (but still link to the doc from NC34 about this) and replace with the new stuff about AppFramework/ORM

Requires nextcloud/server#63441 to be merged first as this mention the change from there

🖼️ Screenshots

image

✅ Checklist

  • I have built the documentation locally and reviewed the output
  • Screenshots are included for visual changes
  • I have not moved or renamed pages (or added a redirect if I did)
  • I have run codespell or similar and addressed any spelling issues

@github-actions

github-actions Bot commented Aug 20, 2026

Copy link
Copy Markdown
Contributor

📖 Documentation Preview

🔍 Open preview →

📄 2 changed documentation pages

Last updated: Thu, 20 Aug 2026 16:25:34 GMT

Assisted-by: ClaudeCode:claude-sonnet-5
Signed-off-by: Carl Schwan <carl@carlschwan.eu>
Signed-off-by: Carl Schwan <carl@carlschwan.eu>
@CarlSchwan
CarlSchwan requested a review from skjnldsv as a code owner August 20, 2026 15:54
@github-actions github-actions Bot added the github_actions Pull requests that update GitHub Actions code label Aug 20, 2026

By default, as in the example above, a bare ``#[Id]`` relies on the database's autoincrement column:
``insert()`` only fills in ``$author->id`` after the row has been written. Pass a ``generatorClass`` to
generate the id application-side, before the row is inserted, instead. ``OCP\Snowflake\ISnowflakeGenerator``

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Shouldn't snowflakes be the first/default examle in the documentation? Assuming we rather want people to use snowflake.

1. Don't use table name longer than 23 characters. As Oracle is limited to 30 chars and we need 3 more for ``oc_`` at the beginning and 5 for the primary key suffix ``_pkey``.

2. Add an auto-incremented ``id`` column. This will ease the use of ``QBMapper`` + ``Entity`` approach:
2. Add an auto-incremented ``id`` column. This will ease the use of the ``Repository`` + attributes approach:

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same comment as above, shouldn't we push for snowflake instead?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

3. to review github_actions Pull requests that update GitHub Actions code manual: developer

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants